package com.neusoft.tijiancms.controller;

import com.neusoft.tijiancms.po.Setmeal;
import com.neusoft.tijiancms.service.SetmealService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/SetmealController")
public class SetmealController {
    @Autowired
    private SetmealService setmealService;
    @RequestMapping("/getSetmealById")
    public Object getSetmealById(Setmeal setmeal){
        return setmealService.getSetmealById(setmeal.getSmId());
    }

    //查询数据
    @RequestMapping("/listSetmeal")
    public List<Setmeal> listSetmeal(){
        return setmealService.listSetmeal();
    }

//    @RequestMapping("/getSetmealData")
//    public List<Setmeal> getSetmealData(Setmeal setmeal){
//        return setmealService.getSetmealData(setmeal);
//    }
}
